<html>
<head><meta charset="utf-8"><title>running lexer test suite · t-compiler · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/index.html">t-compiler</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html">running lexer test suite</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="162508283"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162508283" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162508283">(Apr 04 2019 at 09:29)</a>:</h4>
<p>What would be the best command to test changes to the lexer?</p>
<p>I am currently using <code>./x.py -i --stage 1 test src/test/ui src/test/run-pass src/test/compile-fail/</code>, is there anything better?</p>



<a name="162509288"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162509288" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162509288">(Apr 04 2019 at 09:47)</a>:</h4>
<p><span class="user-mention" data-user-id="133169">@matklad</span>  fastest way would be to <code>cargo foobar</code> in <code>src/libsyntax</code> I think</p>



<a name="162509357"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162509357" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162509357">(Apr 04 2019 at 09:48)</a>:</h4>
<p>that only works if you can roll your unit tests there tho</p>



<a name="162509399"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162509399" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162509399">(Apr 04 2019 at 09:49)</a>:</h4>
<p>there are dedicated parser tests in <code>src/test/ui/parser</code>, so if you want to narrow your focus, I'd just feed in that path.</p>



<a name="162509528"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162509528" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> pnkfelix <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162509528">(Apr 04 2019 at 09:51)</a>:</h4>
<p>(also, "better" is slightly ambiguous in your original question: Are you trying to minimize testing time? Or maximize coverage? Or minimize rustc recompile times?)</p>



<a name="162509637"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/131828-t-compiler/topic/running%20lexer%20test%20suite/near/162509637" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/131828-t-compiler/topic/running.20lexer.20test.20suite.html#162509637">(Apr 04 2019 at 09:53)</a>:</h4>
<p>What I am trying to do is to extract the actual lexing part of the lexer (as opposed to interning, span management and all that stuff) into a separate crate. So, I am doing a refactoring, and interested in maximally fast rebuilds with 90% condidence that I didn't break stuff</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>